<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
		<style type="text/css">
			#box{
				width: 100px;
				height: 100px;
				border: 1px solid red;
				display: none;
			}
		</style>
	</head>
	<body>
		<div id="box">
			
		</div>
		<button id="btn">隐藏</button>
		
		
	</body>
	<script src="../jquery-3.2.1.js"></script>
	
	<script type="text/javascript">
		$(function(){
			
			
			/*
			$('#btn').hover(function(){
				$('#box').slideDown(2000);
				
			},function(){
				$('#box').slideUp(2000);
			})
			*/
			
			$('#btn').click(function(){
				$('#box').slideToggle('fast');
			})
			
		})
		
	</script>
</html>
